/*
 * ChequeRecebido.java
 *
 * Created on October 12, 2007, 10:46 PM
 *
 * To change this template, choose Tools | Template Manager
 * and open the template in the editor.
 */

package petstore.model;

import java.util.Collection;
import javax.persistence.AttributeOverride;
import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.OneToMany;
import javax.persistence.Table;

/**
 * Entity class ChequeRecebido
 * 
 * @author Tom Hayden
 */
@Entity
@Table(name = "cheque_recebido")
@AttributeOverride(name="id", column=@Column(name="cdchequerecebido"))
public class ChequeRecebido extends BusinessObject {

    @Column(name = "cdbanco")
    private String banco;

    @Column(name = "nragencia")
    private String agencia;

    @Column(name = "nrcheque")
    private String numeroCheque;

    @Column(name = "compensado")
    private boolean compensado;

    @Column(name = "ativo")
    private boolean active;

    @OneToMany(cascade = CascadeType.ALL)
    private Collection<OcorrenciaCheque> ocorrenciasCheque;

    /** Creates a new instance of ChequeRecebido */
    public ChequeRecebido() {
    }

    public String getBanco() {
        return banco;
    }

    public void setBanco(String banco) {
        this.banco = banco;
    }

    public String getAgencia() {
        return agencia;
    }

    public void setAgencia(String agencia) {
        this.agencia = agencia;
    }

    public String getNumeroCheque() {
        return numeroCheque;
    }

    public void setNumeroCheque(String numeroCheque) {
        this.numeroCheque = numeroCheque;
    }

    public boolean getCompensado() {
        return compensado;
    }

    public void setCompensado(boolean compensado) {
        this.compensado = compensado;
    }

    public boolean isActive() {
        return active;
    }

    public void setActive(boolean active) {
        this.active = active;
    }

    public Collection<OcorrenciaCheque> getOcorrenciasCheque() {
        return ocorrenciasCheque;
    }

    public void setOcorrenciasCheque(Collection<OcorrenciaCheque> ocorrenciasCheque) {
        this.ocorrenciasCheque = ocorrenciasCheque;
    }

}
